package com.ruoyi.kiku.service.impl;

import java.util.List;
import com.ruoyi.common.utils.DateUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.kiku.mapper.KikuWeiBoConcernMapper;
import com.ruoyi.kiku.domain.KikuWeiBoConcern;
import com.ruoyi.kiku.service.IKikuWeiBoConcernService;

/**
 * 微博关注Service业务层处理
 *
 * @author TT
 * @date 2025-08-03
 */
@Service
public class KikuWeiBoConcernServiceImpl implements IKikuWeiBoConcernService
{
    @Autowired
    private KikuWeiBoConcernMapper kikuWeiBoConcernMapper;

    /**
     * 查询微博关注
     *
     * @param id 微博关注主键
     * @return 微博关注
     */
    @Override
    public KikuWeiBoConcern selectKikuWeiBoConcernById(Long id)
    {
        return kikuWeiBoConcernMapper.selectKikuWeiBoConcernById(id);
    }

    /**
     * 查询微博关注列表
     *
     * @param kikuWeiBoConcern 微博关注
     * @return 微博关注
     */
    @Override
    public List<KikuWeiBoConcern> selectKikuWeiBoConcernList(KikuWeiBoConcern kikuWeiBoConcern)
    {
        return kikuWeiBoConcernMapper.selectKikuWeiBoConcernList(kikuWeiBoConcern);
    }

    /**
     * 新增微博关注
     *
     * @param kikuWeiBoConcern 微博关注
     * @return 结果
     */
    @Override
    public int insertKikuWeiBoConcern(KikuWeiBoConcern kikuWeiBoConcern)
    {
        kikuWeiBoConcern.setCreateTime(DateUtils.getNowDate());
        return kikuWeiBoConcernMapper.insertKikuWeiBoConcern(kikuWeiBoConcern);
    }

    /**
     * 修改微博关注
     *
     * @param kikuWeiBoConcern 微博关注
     * @return 结果
     */
    @Override
    public int updateKikuWeiBoConcern(KikuWeiBoConcern kikuWeiBoConcern)
    {
        kikuWeiBoConcern.setUpdateTime(DateUtils.getNowDate());
        return kikuWeiBoConcernMapper.updateKikuWeiBoConcern(kikuWeiBoConcern);
    }

    /**
     * 批量删除微博关注
     *
     * @param ids 需要删除的微博关注主键
     * @return 结果
     */
    @Override
    public int deleteKikuWeiBoConcernByIds(Long[] ids)
    {
        return kikuWeiBoConcernMapper.deleteKikuWeiBoConcernByIds(ids);
    }

    /**
     * 删除微博关注信息
     *
     * @param id 微博关注主键
     * @return 结果
     */
    @Override
    public int deleteKikuWeiBoConcernById(Long id)
    {
        return kikuWeiBoConcernMapper.deleteKikuWeiBoConcernById(id);
    }

    /**
     * 批量插入微博关注信息
     * @param exportObject
     * @return int
     */
    @Override
    public int BatchInsertKikuWeiBoConcern(List<KikuWeiBoConcern> exportObject) {
        return kikuWeiBoConcernMapper.BatchInsertKikuWeiBoConcern(exportObject);
    }
}
